package cn.iocoder.yudao.module.booking.controller.admin.course.vo;

import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

@Schema(description = "管理后台 - 预约管理 Response VO")
@Data
@ExcelIgnoreUnannotated
public class CourseRespVO {

    @Schema(description = "编号", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("编号")
    private Long id;

    @Schema(description = "课程编号", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("课程编号")
    private Long courseInfoId;

    @Schema(description = "预约人手机号", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("预约人手机号")
    private String bookingPhone;

    @Schema(description = "预约人姓名", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("预约人姓名")
    private String bookingName;

    @Schema(description = "预约状态(0取消，1成功)")
    @ExcelProperty(value = "预约状态(0取消，1成功)", converter = DictConvert.class)
    @DictFormat("course_booking_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Integer status;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

    @Schema(description = "课程标题", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("课程标题")
    private String title;

    @Schema(description = "课程描述", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("课程描述")
    private String description;

    @Schema(description = "课程开始时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("课程开始时间")
    private LocalDateTime startTime;

    @Schema(description = "课程结束时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("课程结束时间")
    private LocalDateTime endTime;

    @Schema(description = "上课人数", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("上课人数")
    private Long number;

    @Schema(description = "已预约人数", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("已预约人数")
    private Long availableNumber;

    @Schema(description = "上课地点", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("上课地点")
    private String place;

    @Schema(description = "教练名字", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("教练名字")
    private String instructorName;

}